﻿using System;
using System.Collections.Generic;
using System.Data;
using System.Linq;
using System.Text;
//using BTGISWASECO.BusinessEntities;

/// <summary>
/// Summary description for DataLoggerEntities
/// </summary>
namespace BTGISWASECO.BusinessEntities
{
    public class DataLoggerEntities
    {
        #region khai bao thuoc tinh
        private int _objectID;
        private string _IDDataLogger;
        private string _IDCapNuoc;
        private int _NhanHieu;
        private string _NhanHieuText;
        private string _TieuChuan;
        private int _NhaSanXuat;
        private string _NhaSanXuatText;
        private int _NuocSanXuat;
        private string _NuocSanXuatText;
        private int _NamSanXuat;
        private int _TinhTrang;
        private string _TinhTrangText;
        private int _DonViQL;
        private string _DonViQLText;
        private int _ThuocSoHuu;
        private string _ThuocSoHuuText;
        private string _MoTaViTri;
        private int _NamLapDat;
        private string _IDDongHoTong;
        private DateTime _NgayCNCuoi;
        private string _NguoiCNCuoi;
        private int _SoLanSuCo;
        private string _IDHinhAnh;

        public string IDHinhAnh
        {
            get { return _IDHinhAnh; }
            set { _IDHinhAnh = value; }
        }


        public string NguoiCNCuoi
        {
            get { return _NguoiCNCuoi; }
            set { _NguoiCNCuoi = value; }
        }

        public DateTime NgayCNCuoi
        {
            get { return _NgayCNCuoi; }
            set { _NgayCNCuoi = value; }
        }

        public int SoLanSuCo
        {
            get { return _SoLanSuCo; }
            set { _SoLanSuCo = value; }
        }

        public int NamLapDat
        {
            get { return _NamLapDat; }
            set { _NamLapDat = value; }
        }

        public string MoTaViTri
        {
            get { return _MoTaViTri; }
            set { _MoTaViTri = value; }
        }

        public int ThuocSoHuu
        {
            get { return _ThuocSoHuu; }
            set { _ThuocSoHuu = value; }
        }

        public string ThuocSoHuuText
        {
            get { return _ThuocSoHuuText; }
            set { _ThuocSoHuuText = value; }
        }

        public int NhaSanXuat
        {
            get { return _NhaSanXuat; }
            set { _NhaSanXuat = value; }
        }

        public string NhaSanXuatText
        {
            get { return _NhaSanXuatText; }
            set { _NhaSanXuatText = value; }
        }

        public string NuocSanXuatText
        {
            get { return _NuocSanXuatText; }
            set { _NuocSanXuatText = value; }
        }

        public int NamSanXuat
        {
            get { return _NamSanXuat; }
            set { _NamSanXuat = value; }
        }

        public int NuocSanXuat
        {
            get { return _NuocSanXuat; }
            set { _NuocSanXuat = value; }
        }


        public string IDDongHoTong
        {
            get { return _IDDongHoTong; }
            set { _IDDongHoTong = value; }
        }


        public string DonViQLText
        {
            get { return _DonViQLText; }
            set { _DonViQLText = value; }
        }

        public string TinhTrangText
        {
            get { return _TinhTrangText; }
            set { _TinhTrangText = value; }
        }


        public string NhanHieuText
        {
            get { return _NhanHieuText; }
            set { _NhanHieuText = value; }
        }

        public string TieuChuan
        {
            get { return _TieuChuan; }
            set { _TieuChuan = value; }
        }


        public int DonViQL
        {
            get { return _DonViQL; }
            set { _DonViQL = value; }
        }


        public int TinhTrang
        {
            get { return _TinhTrang; }
            set { _TinhTrang = value; }
        }

        public int NhanHieu
        {
            get { return _NhanHieu; }
            set { _NhanHieu = value; }
        }
        
        public int OBJECTID
        {
            get { return _objectID; }
            set { _objectID = value; }
        }

        public string IDDataLogger
        {
            get { return _IDDataLogger; }
            set { _IDDataLogger = value; }
        }

        public string IDCapNuoc
        {
            get { return _IDCapNuoc; }
            set { _IDCapNuoc = value; }
        }


        # endregion khai bao

        #region phuong thuc

        public DataLoggerEntities()
        {

        }

        public DataLoggerEntities(string IDDataLogger, int NhanHieu,
                                string TieuChuan, int NhaSanXuat, int NuocSanXuat, int NamSanXuat,
                                int TinhTrang, int DonViQL, int ThuocSoHuu, string MoTaViTri,
                                int NamLapDat, string IDDongHoTong, DateTime NgayCNCuoi, string NguoiCNCuoi,
                                int SoLanSuCo, string IDHinhAnh)
        {
            this._IDDataLogger = IDDataLogger;
            this._NhanHieu = NhanHieu;
            this._TieuChuan = TieuChuan;
            this._NhanHieu = NhanHieu;
            this._NhaSanXuat = NhaSanXuat;
            this._NuocSanXuat = NuocSanXuat;
            this._NamSanXuat = NamSanXuat;
            this._TinhTrang = TinhTrang;
            this._DonViQL = DonViQL;
            this._ThuocSoHuu = ThuocSoHuu;
            this._MoTaViTri = MoTaViTri;
            this._NamLapDat = NamLapDat;
            this._IDDongHoTong = IDDongHoTong;
            this._NgayCNCuoi = NgayCNCuoi;
            this._NguoiCNCuoi = NguoiCNCuoi;
            this._SoLanSuCo = SoLanSuCo;
            this._IDHinhAnh = IDHinhAnh;
        }
        public DataLoggerEntities(int OBJECTID, string IDDataLogger,  int NhanHieu,
                                string TieuChuan, int NhaSanXuat, int NuocSanXuat, int NamSanXuat,
                                int TinhTrang, int DonViQL, int ThuocSoHuu, string MoTaViTri,
                                int NamLapDat, string IDDongHoTong, DateTime NgayCNCuoi, string NguoiCNCuoi,
                                int SoLanSuCo, string IDHinhAnh)
        {
            this._objectID = OBJECTID;
            this._IDDataLogger = IDDataLogger;
            this._NhanHieu = NhanHieu;
            this._TieuChuan = TieuChuan;
            this._NhanHieu = NhanHieu;
            this._NhaSanXuat = NhaSanXuat;
            this._NuocSanXuat = NuocSanXuat;
            this._NamSanXuat = NamSanXuat;
            this._TinhTrang = TinhTrang;
            this._DonViQL = DonViQL;
            this._ThuocSoHuu = ThuocSoHuu;
            this._MoTaViTri = MoTaViTri;
            this._NamLapDat = NamLapDat;
            this._IDDongHoTong = IDDongHoTong;
            this._NgayCNCuoi = NgayCNCuoi;
            this._NguoiCNCuoi = NguoiCNCuoi;
            this._SoLanSuCo = SoLanSuCo;
            this._IDHinhAnh = IDHinhAnh;
        }

        public DataLoggerEntities(DataRow row)
        {
            this._objectID = Convert.ToInt32(row["OBJECTID"]);
            this._IDDataLogger = row["IDDataLogger"].ToString();
            this._IDCapNuoc = row["IDCapNuoc"].ToString();
            this._NhanHieuText = row["NhanHieu"].ToString();
            this._TieuChuan = row["TieuChuan"].ToString();
            this._NhaSanXuatText = row["NhaSanXuat"].ToString();
            this._NuocSanXuatText = row["NuocSanXuat"].ToString();
            this._NamSanXuat = Convert.ToInt32(row["NamSanXuat"]);            
            this._TinhTrangText = row["TinhTrang"].ToString();
            this._DonViQLText = row["DonViQuanLy"].ToString();
            this._ThuocSoHuuText = row["ThuocSoHuu"].ToString();
            this._MoTaViTri = row["MoTaViTri"].ToString();
            this._NamLapDat = Convert.ToInt32(row["NamLapDat"]); 
            this._IDDongHoTong = row["IDDongHoTong"].ToString();
            if (row["NgayCNCuoi"].ToString() != "Null")
                this._NgayCNCuoi = Convert.ToDateTime(row["NgayCNCuoi"]);
            this._NguoiCNCuoi = row["NguoiCNCuoi"].ToString();
            this._SoLanSuCo = Convert.ToInt32(row["SoLanSuCo"]);
            this._IDHinhAnh = row["IDHinhAnh"].ToString();

        }

        #endregion phuong thuc
    }
}